package com.daidai.mapper;

import com.daidai.domain.User;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface UserMapper {

    @Select("select * from user where id = #{id}")
    User findAllUsersById(int id);

    @Insert("insert into user(username, password) values(#{username}, #{password})")
    void insert(User user);

    @Delete("delete from user where id = #{id}")
    void delete(int id);
}
